package com.example.rabbitmq.receiver;

import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * Copyright(C), 2020-2021, AmbroseCdMeng
 * FileName:    TopicReceiverA
 * Author:      AmbroseCdMeng
 * Date:        2021/3/2 10:15
 * Description: 编写接收者A。实现用接收器接收多个主题
 * History:
 * <author>     <time>      <version>       <desc>
 * 作者姓名     修改时间        版本号           描述
 */
@Component
@RabbitListener(queues = "topic.a")
public class TopicReceiverA {
    @RabbitHandler
    public void process(String msg){
        System.out.println("Topic ReceiverA: " + msg);
    }
}
